<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:p="http://primefaces.org/ui"
                template="./../resources/templates/publicTemplate.xhtml">
    <ui:define name="header">
        
        <h:outputStylesheet library="css" name="customPrimefaces.css"/>
    </ui:define>
    <ui:define name="leftContent">
        <h:form id="frmHome"> 
            <p:dataTable
                value="#{homeBean.eventosAnunciados}"
                paginator="true" rows="5" 
                rowsPerPageTemplate="5,10"
                paginatorPosition="bottom"
                paginatorTemplate="{FirstPageLink} {PreviousPageLink} {PageLinks} {NextPageLink} {LastPageLink} {RowsPerPageDropdown}"
                var="evento"
                styleClass="gridNoLine"
                style="width: 100%;">
                <p:column styleClass="ui-widget-content">

                    <p:panelGrid
                        columns="2">
                        <p:panelGrid columns="1"
                                     styleClass="gridNoLine">
                            <h:outputLabel value="#{evento.nmeEvento}"
                                           styleClass="t2 wrap"/>
                            <p:separator />
                            <h:graphicImage alt="#{evento.nmeEvento}"
                                            library="images"
                                            name="#{evento.urlImagemEvento}"
                                            styleClass="imagemAnuncio"/>
                            <h:outputLabel value="#{evento.dscEvento}"
                                           styleClass="t3"/>
                            <p:commandButton value="Inscrever"
                                             styleClass="btn-primary"
                                             action="inscricao"
                                             ajax="false"/>
                        </p:panelGrid>
                    </p:panelGrid>
                </p:column>
            </p:dataTable>
        </h:form>
    </ui:define>
    <ui:define name="rightContent">

    </ui:define>
</ui:composition>